/**
 * @UiEvent.hpp
 * Copyright 2013 (C) FatalEror / Dean Bahari
 * 
 * UiPack is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 * 
 * See LICENSE file in main folder for more information.
 */

#ifndef _UI_EVENT_HPP_
#define _UI_EVENT_HPP_

class UiEvent {
	HDC   mDC;
	POINT mPoint;
	RECT  mRect;
	int   mState;
	bool  mToggle;
public:
	UiEvent();
	UiEvent(int left, int top, int right, int bottom);
	UiEvent(RECT rc);
	UiEvent(int x, int y);
	UiEvent(POINT pt);
	UiEvent(bool toggle);
	UiEvent(int state);
	UiEvent(HDC hDC);

	int   getWidth();
	int   getHeight();
	int   getPosX();
	int   getPosY();
	int   getLeft();
	int   getTop();
	int   getRight();
	int   getBottom();
	HDC   getDC();
	POINT getPoint();
	RECT  getRect();
	int   getState();

	bool isLeftClick();
	bool isRightClick();
	bool isMiddleClick();
	bool isLeftRelease();
	bool isRightRelease();
	bool isMiddleRelease();

	enum Type {
		UI_MOUSE_LEFT    = 0x001,
		UI_MOUSE_MIDDLE  = 0x002,
		UI_MOUSE_RIGHT   = 0x004,
		UI_MOUSE_CLICK   = 0x010,
		UI_MOUSE_DCLICK  = 0x020,
		UI_MOUSE_RELEASE = 0x040,

		UI_WINDOW_MAXIMIZED,
		UI_WINDOW_RESTORED,
		UI_WINDOW_MINIMIZED,
	};
};

#endif//_UI_EVENT_HPP_